package com.game.code;

import org.jbox2d.dynamics.World;

public class Level {
	public static final float WORLD_PHYSICS_SIZE = 10;


	public static final float HORIZONTAL_N = 10;
	public static final float VERTICAL_N = 10;

	public static final float HORIZONTAL_W = WORLD_PHYSICS_SIZE*8/9;
	public static final float VERTICAL_H = WORLD_PHYSICS_SIZE/3;

	public static final float HEIGHT = -WORLD_PHYSICS_SIZE/4;

	public Level(World world){
		for(int x=0;x<HORIZONTAL_N;x++){
			for(int y=0;y<HORIZONTAL_N;y++){

				new Brick(world,
						  x*(HORIZONTAL_W/HORIZONTAL_N)-HORIZONTAL_W/2+(HORIZONTAL_W/HORIZONTAL_N/2),
						  y*(VERTICAL_H/VERTICAL_N)-VERTICAL_H/2+HEIGHT+(VERTICAL_H/VERTICAL_N/2),
						  HORIZONTAL_W/HORIZONTAL_N*18/19,
						  VERTICAL_H/VERTICAL_N*8/9);
			}
		}
	}
}
